﻿<%@ Page Title="Log In" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="True"
    CodeBehind="TU_Company.aspx.cs" Inherits="JOIN.APTS.Apps.TU_Company" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
    <script src="../Scripts/editPage.js" type="text/javascript"></script>
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
    <!-- Add.aspx -->
    <ajaxToolkit:ToolkitScriptManager ID="scriptmanager1" runat="server" />
    <table cellspacing="0" cellpadding="0" width="100%" border="0" class="InputTable">
        <tr>
            <td height="25" width="30%" align="right" class="InputLabel">
                企业编码：
            </td>
            <td height="25" width="*" align="left">
                <asp:TextBox ID="txtID" runat="server" Style="display: none;" />
                <asp:TextBox ID="txtCompanyID" runat="server" />
            </td>
            <td height="25" width="30%" align="right" class="InputLabel">
                企业名称：
            </td>
            <td height="25" width="*" align="left">
                <asp:TextBox ID="txtCompanyName" runat="server" />
            </td>
        </tr>
        <tr>
            <td height="25" width="30%" align="right" class="InputLabel">
                地址：
            </td>
            <td height="25" width="*" align="left" colspan="3">
                <asp:TextBox ID="txtAddress" runat="server" Width="80%" />
            </td>
        </tr>
        <tr>
            <td height="25" width="30%" align="right" class="InputLabel">
                联系人：
            </td>
            <td height="25" width="*" align="left">
                <asp:TextBox ID="txtLinkPerson" runat="server" />
            </td>
            <td height="25" width="30%" align="right" class="InputLabel">
                联系人电话：
            </td>
            <td height="25" width="*" align="left">
                <asp:TextBox ID="txtLinkPersonMobile" runat="server" />
            </td>
        </tr>
        <tr>
            <td height="25" width="30%" align="right" class="InputLabel">
                所属机构：
            </td>
            <td height="25" width="*" align="left">
                <Kevin:CodeNameSelect ID="cns_OrgID" runat="server" ServicePath="~/Services/CodeNameService.asmx"
                    ServiceMethod="GetOrg" MinimumPrefixLength="0" />
            </td>
        </tr>
        <tr>
            <td colspan="4" align="center">
                <input id="btnSave" value="保存" type="button" class="btn" />&nbsp;&nbsp;<input id="btnDel"
                    value="删除" type="button" class="btn" />
            </td>
        </tr>
    </table>
    <div>
    </div>
    <Kevin:DataBind ID="databind1" runat="server" ServicePath="~/Services/BLLService.asmx"
        ServiceMethod="CompanyService" ClientDataBind="true">
        <CommandItems>
            <Kevin:CommandItem ControlID="btnSave" CommandType="Save" ServiceMethod="CompanyService"
                CallbackMethod="ShowCompanyID" />
            <Kevin:CommandItem ControlID="btnDel" CommandType="Del" ServiceMethod="CompanyService"
                CallbackMethod="$editPage.close" />
        </CommandItems>
        <BindItems>
            <Kevin:DataBindItem ControlID="txtID" DataPropertyName="ID" IsPrimary="true" />
            <Kevin:DataBindItem ControlID="txtCompanyID" DataPropertyName="CompanyID" />
            <Kevin:DataBindItem ControlID="txtCompanyName" DataPropertyName="CompanyName" />
            <Kevin:DataBindItem ControlID="txtAddress" DataPropertyName="Address" />
            <Kevin:DataBindItem ControlID="txtLinkPerson" DataPropertyName="LinkPerson" />
            <Kevin:DataBindItem ControlID="txtLinkPersonMobile" DataPropertyName="LinkPersonMobile" />
            <Kevin:DataBindItem ControlID="cns_OrgID" DataPropertyName="OrgID" ControlPropertyName="Value"
                GetValueClientMethod="_getCodeNameSelectValue" />
        </BindItems>
    </Kevin:DataBind>
    <script>
        function ShowCompanyID(obj) {
            $get('<%=txtID.ClientID %>').value = obj.ID;
        }
    </script>
</asp:Content>
